package com.dhcc.model;

import javax.persistence.*;

/**
 * Created by guorui on 2017/3/17.
 */
@Entity
@Table(name = "tb_te_cou_rel", schema = "test", catalog = "")
public class TeCouRel {
    private int id;
    private int teaId;
    private int cId;

    @Id
    @Column(name = "id", nullable = false)
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    @Basic
    @Column(name = "tea_id", nullable = false)
    public int getTeaId() {
        return teaId;
    }

    public void setTeaId(int teaId) {
        this.teaId = teaId;
    }

    @Basic
    @Column(name = "c_id", nullable = false)
    public int getcId() {
        return cId;
    }

    public void setcId(int cId) {
        this.cId = cId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        TeCouRel teCouRel = (TeCouRel) o;

        if (id != teCouRel.id) return false;
        if (teaId != teCouRel.teaId) return false;
        if (cId != teCouRel.cId) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id;
        result = 31 * result + teaId;
        result = 31 * result + cId;
        return result;
    }
}
